Optimal Algorithms for Finding the Longest Path with Length and Sum Constraints in a Tree

نویسنده

  • Sung Kwon Kim
چکیده

Let T be a tree in which every edge is associated with a real number. The sum of a path in T is the sum of the numbers associated with the edges of the path and its length is the number of the edges in it. For two positive integers L1 ≤ L2 and two real numbers S1 ≤ S2, a path is feasible if its length is between L1 and L2 and its sum is between S1 and S2. We address the problem: Given a tree T , and four numbers, L1, L2, S1 and S2, find the longest feasible path of T . We provide an optimal O(n logn) time algorithm for the problem, where n = |T |. key words: length constraint, longest path, sum constraint, tree.

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Optimal Online and Offline Algorithms for Finding Longest and Shortest Subsequences with Length and Sum Constraints

In this paper, we address the following problems: Given a sequence A of n real numbers, and four parameters I, J,X and Y with I ≤ J and X ≤ Y , find the longest (or shortest) subsequence of A such that its length is between I and J and its sum is between X and Y . We present an online and an offline algorithm for the problems, both run in O(n logn) time, which are optimal. key words: length con...

متن کامل

Optimal Algorithms for Finding Density-Constrained Longest and Heaviest Paths in a Tree

Let T be a tree with n nodes, in which each edge is associated with a length and a weight. The density-constrained longest (heaviest) path problem is to find a path of T with maximum path length (weight) whose path density is bounded by an upper bound and a lower bound. The path density is the path weight divided by the path length. We show that both problems can be solved in optimal O(n logn) ...

متن کامل

Two optimal algorithms for finding bi-directional shortest path design problem in a block layout

In this paper, Shortest Path Design Problem (SPDP) in which the path is incident to all cells is considered. The bi-directional path is one of the known types of configuration of networks for Automated Guided Vehi-cles (AGV).To solve this problem, two algorithms are developed. For each algorithm an Integer Linear Pro-gramming (ILP) is determined. The objective functions of both algorithms are t...

متن کامل

Algorithms for finding the weight-constrained k longest paths in a tree and the length-constrained k maximum-sum segments of a sequence

In this work, we obtain the following new results: – Given a tree T = (V, E) with a length function ` : E → R and a weight function w : E → R, a positive integer k, and an interval [L, U ], the Weight-Constrained k Longest Paths problem is to find the k longest paths among all paths in T with weights in the interval [L,U ]. We show that the Weight-Constrained k Longest Paths problem has a lower...

متن کامل

Optimum Routing in the Urban Transportation Network by Integrating Genetic Meta-heuristic (GA) and Tabu Search (Ts) Algorithms

Urban transportation is one of the most important issues of urban life especially in big cities. Urban development, and subsequently the increase of routes and communications, make the role of transportation science more pronounced. The shortest path problem in a network is one of the most basic network analysis issues. In fact, finding answers to this question is necessity for higher level ana...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

عنوان ژورنال:
  • IEICE Transactions

دوره 94-D  شماره 

صفحات  -

تاریخ انتشار 2011